---
layout: default
---

{% include home-header.html %} {%- assign date_format = site.date_format |
default: "%Y-%m-%d %H:%M" -%}

<div class="posts">
  {% for post in paginator.posts %}
  <section class="post-entry">
    <h2 class="post-title">
      <a href="{{ post.url | relative_url }}"> {{ post.title }} </a>
    </h2>

    <div class="post-meta">
      <!--      <time datetime="{{ post.date | date_to_xmlschema }}">{{ post.date | date_to_string }}</time>-->
      <time datetime="{{ post.date | date_to_xmlschema }}"
        >{{ post.date | date: date_format }}</time
      >
      {%- if jekyll.environment == "production" and site.disqus -%}
      <span> • </span>
      <a
        class="comment-count"
        href="{{ post.url | relative_url }}#disqus_thread"
      >
        <span
          class="disqus-comment-count"
          data-disqus-url="{{ post.url | absolute_url }}"
        ></span>
      </a>
      {%- endif -%}
    </div>

    <p>{{ post.excerpt | strip_html }}</p>
  </section>
  {% endfor %} {%- if jekyll.environment == "production" and site.disqus -%}
  <script
    id="dsq-count-scr"
    src="//{{ site.disqus }}.disqus.com/count.js"
    async
  ></script>
  {%- endif -%}
</div>

<div class="pagination">
  {% if paginator.next_page %}
  <a
    class="pagination-item older"
    href="{{ paginator.next_page_path | relative_url }}"
    >上一页</a
  >
  {% else %}
  <span class="pagination-item older">上一页</span>
  {% endif %} {% if paginator.previous_page %}
  <a
    class="pagination-item newer"
    href="{{ paginator.previous_page_path | prepend: relative_url }}"
    >下一页</a
  >
  {% else %}
  <span class="pagination-item newer">下一页</span>
  {% endif %}
</div>
